'use strict'

var path = require('path')

// 解析当前文件所在目录:
var workDir = path.resolve(__dirname) // '/Users/michael'

// 组合完整的文件路径:当前文件所在目录+'pub'+'index.html':
var filePath = path.join(workDir, 'pub', 'index.html')
// '/Users/michael/pub/index.html'
console.log(filePath)

//
console.log(path.parse('./foo/bar/baz/asdf/////quux.js'))
